from django.http import HttpResponse
from django.shortcuts import render

# def index(request):
#     """
#     测试页面首页
#     :params request: HttpRequest, http请求
#     :return: Response, 对请求的响应
#     """
#
#     # 尝试读取用户信息 当读取失败时返回None 此处直接使用 request.session["username"] 会报错
#     username = request.session.get('username', None)
#     if username is None:
#         print("未发现用户信息")
#
#         # 设置用户信息
#         request.session["username"] = "zhangsan"
#     else:
#         print("发现用户信息" + username)
#
#     return HttpResponse('success')


# 查询订单列表
def order_list(request):
    return render(request, 'visites/temp-orders.html')


# 查询菜谱列表
def menu_list(request):
    return render(request, 'visites/temp-menu.html')
